package com.cet.regularexpression;

/**
 * @program: algorithm
 * @description:
 * @author: 陈恩涛
 * @create: 2021-06-18 17:27
 **/
public class Main02 {
    public static void main(String[] args) {
        String regex1 = "abc";
        System.out.println("abc".matches(regex1));
        System.out.println("Abc".matches(regex1));
        System.out.println("abcd".matches(regex1));

        // 对应的正则是a\&c
        String regex2 = "a&c";
        System.out.println("a&c".matches(regex2));
        System.out.println("a-c".matches(regex2));
        System.out.println("a&&c".matches(regex2));

        String regex3 = "a\\u548cc";
        System.out.println("a和c".matches(regex3));
    }
}
